package com.zly.distributed.lock.lock;

import jakarta.annotation.Resource;
import org.springframework.data.redis.core.StringRedisTemplate;
import org.springframework.stereotype.Component;

@Component
public class DescributedLockClient {
    @Resource
    private StringRedisTemplate stringRedisTemplate;

    public DescributedRedisLock getRedisLock(String lockName) {
        return new DescributedRedisLock(stringRedisTemplate, lockName);
    }
}
